set(_BLE_HOST_TAG_MAP
    # BTM Layer
    CONFIG_BLE_BLUEDROID_BTM_ERROR_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_BTM_ERROR_LOG_PRESERVE
    BTM_TRACE_ERROR

    CONFIG_BLE_BLUEDROID_BTM_WARNING_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_BTM_WARNING_LOG_PRESERVE
    BTM_TRACE_WARNING

    CONFIG_BLE_BLUEDROID_BTM_API_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_BTM_API_LOG_PRESERVE
    BTM_TRACE_API

    CONFIG_BLE_BLUEDROID_BTM_EVENT_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_BTM_EVENT_LOG_PRESERVE
    BTM_TRACE_EVENT

    CONFIG_BLE_BLUEDROID_BTM_DEBUG_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_BTM_DEBUG_LOG_PRESERVE
    BTM_TRACE_DEBUG

    CONFIG_BLE_BLUEDROID_BTM_VERBOSE_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_BTM_VERBOSE_LOG_PRESERVE
    BTM_TRACE_VERBOSE

    # L2CAP Layer
    CONFIG_BLE_BLUEDROID_L2CAP_ERROR_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_L2CAP_ERROR_LOG_PRESERVE
    L2CAP_TRACE_ERROR

    CONFIG_BLE_BLUEDROID_L2CAP_WARNING_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_L2CAP_WARNING_LOG_PRESERVE
    L2CAP_TRACE_WARNING

    CONFIG_BLE_BLUEDROID_L2CAP_API_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_L2CAP_API_LOG_PRESERVE
    L2CAP_TRACE_API

    CONFIG_BLE_BLUEDROID_L2CAP_EVENT_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_L2CAP_EVENT_LOG_PRESERVE
    L2CAP_TRACE_EVENT

    CONFIG_BLE_BLUEDROID_L2CAP_DEBUG_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_L2CAP_DEBUG_LOG_PRESERVE
    L2CAP_TRACE_DEBUG

    CONFIG_BLE_BLUEDROID_L2CAP_VERBOSE_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_L2CAP_VERBOSE_LOG_PRESERVE
    L2CAP_TRACE_VERBOSE

    # GAP Layer
    CONFIG_BLE_BLUEDROID_GAP_ERROR_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GAP_ERROR_LOG_PRESERVE
    GAP_TRACE_ERROR

    CONFIG_BLE_BLUEDROID_GAP_WARNING_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GAP_WARNING_LOG_PRESERVE
    GAP_TRACE_WARNING

    CONFIG_BLE_BLUEDROID_GAP_API_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GAP_API_LOG_PRESERVE
    GAP_TRACE_API

    CONFIG_BLE_BLUEDROID_GAP_EVENT_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GAP_EVENT_LOG_PRESERVE
    GAP_TRACE_EVENT

    CONFIG_BLE_BLUEDROID_GAP_DEBUG_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GAP_DEBUG_LOG_PRESERVE
    GAP_TRACE_DEBUG

    CONFIG_BLE_BLUEDROID_GAP_VERBOSE_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GAP_VERBOSE_LOG_PRESERVE
    GAP_TRACE_VERBOSE

    # GATT Layer
    CONFIG_BLE_BLUEDROID_GATT_ERROR_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GATT_ERROR_LOG_PRESERVE
    GATT_TRACE_ERROR

    CONFIG_BLE_BLUEDROID_GATT_WARNING_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GATT_WARNING_LOG_PRESERVE
    GATT_TRACE_WARNING

    CONFIG_BLE_BLUEDROID_GATT_API_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GATT_API_LOG_PRESERVE
    GATT_TRACE_API

    CONFIG_BLE_BLUEDROID_GATT_EVENT_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GATT_EVENT_LOG_PRESERVE
    GATT_TRACE_EVENT

    CONFIG_BLE_BLUEDROID_GATT_DEBUG_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GATT_DEBUG_LOG_PRESERVE
    GATT_TRACE_DEBUG

    CONFIG_BLE_BLUEDROID_GATT_VERBOSE_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_GATT_VERBOSE_LOG_PRESERVE
    GATT_TRACE_VERBOSE

    # SMP Layer
    CONFIG_BLE_BLUEDROID_SMP_ERROR_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_SMP_ERROR_LOG_PRESERVE
    SMP_TRACE_ERROR

    CONFIG_BLE_BLUEDROID_SMP_WARNING_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_SMP_WARNING_LOG_PRESERVE
    SMP_TRACE_WARNING

    CONFIG_BLE_BLUEDROID_SMP_API_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_SMP_API_LOG_PRESERVE
    SMP_TRACE_API

    CONFIG_BLE_BLUEDROID_SMP_EVENT_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_SMP_EVENT_LOG_PRESERVE
    SMP_TRACE_EVENT

    CONFIG_BLE_BLUEDROID_SMP_DEBUG_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_SMP_DEBUG_LOG_PRESERVE
    SMP_TRACE_DEBUG

    CONFIG_BLE_BLUEDROID_SMP_VERBOSE_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_SMP_VERBOSE_LOG_PRESERVE
    SMP_TRACE_VERBOSE

    # APPL Layer
    CONFIG_BLE_BLUEDROID_APPL_ERROR_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_APPL_ERROR_LOG_PRESERVE
    APPL_TRACE_ERROR

    CONFIG_BLE_BLUEDROID_APPL_WARNING_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_APPL_WARNING_LOG_PRESERVE
    APPL_TRACE_WARNING

    CONFIG_BLE_BLUEDROID_APPL_API_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_APPL_API_LOG_PRESERVE
    APPL_TRACE_API

    CONFIG_BLE_BLUEDROID_APPL_EVENT_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_APPL_EVENT_LOG_PRESERVE
    APPL_TRACE_EVENT

    CONFIG_BLE_BLUEDROID_APPL_DEBUG_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_APPL_DEBUG_LOG_PRESERVE
    APPL_TRACE_DEBUG

    CONFIG_BLE_BLUEDROID_APPL_VERBOSE_LOG_COMPRESSION
    CONFIG_BLE_BLUEDROID_APPL_VERBOSE_LOG_PRESERVE
    APPL_TRACE_VERBOSE

)

include(${CMAKE_CURRENT_LIST_DIR}/tag_table_function.cmake)

set(BLE_HOST_TAGS "")
set(BLE_HOST_TAGS_PRESERVE "")
tag_table_to_lists(_BLE_HOST_TAG_MAP BLE_HOST_TAGS BLE_HOST_TAGS_PRESERVE)
set(BLE_HOST_TAGS          "${BLE_HOST_TAGS}"          PARENT_SCOPE)
set(BLE_HOST_TAGS_PRESERVE "${BLE_HOST_TAGS_PRESERVE}" PARENT_SCOPE)
